<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>在此处插入标题</title>
</head>
<body>
 <%
 	//session.setMaxInactiveInterval(50);//
 	//先判断一下
 	String name=(String)session.getAttribute("USER_LOGIN");
 	if(name==null){
 		//location=''
 		out.print("<script>alert('您还没有登录，给钱也不卖');location.replace('login.jsp');</script>");
 		return;
 	}
  %>
  <h2>欢迎<%=name%>&nbsp;&nbsp;<a href="logout.jsp">退出</a></h2>
  
<ul>
 

  <%
  	out.print(session.getId()+"<br/>有效时间："+session.getMaxInactiveInterval()+"秒");
  	
   %>
  <h1>欢迎<%=name%></h1>
 <% 
 out.print("<h1>下面是我们班6大帅哥，喜欢谁，一万两银子拖走</h1>");
  String []ar={"李本松","陈兵","戴颖","胡冰冰","方亚兵","朱峰"};
  for(int i=0;i<ar.length;i++){
  %>
  <li><%=ar[i]%></li>
  <%}%>
 
 </ul> 
</body>
</html>